<div class="products form">
<?php echo $this->ExtendedForm->create('Product', array('novalidate' => 'novalidate'));?>
	<h3><?php echo __d('admin', 'Add Product'); ?></h3>
	<?php
		if(isset($this->request->params['named']['name'])) echo '<div style="display: none;">';
		echo $this->ExtendedForm->input('name', array_merge(array('label' => __d('admin', 'Name'))));
		if(isset($this->request->params['named']['name'])) echo '</div>';

		if(isset($this->request->params['named']['image'])) echo '<div style="display: none;">';
		echo $this->ExtendedForm->input('image', array_merge(array('type' => 'image', 'label' => __d('admin', 'Image'))));
		if(isset($this->request->params['named']['image'])) echo '</div>';

		if(isset($this->request->params['named']['price'])) echo '<div style="display: none;">';
		echo $this->ExtendedForm->input('price', array_merge(array('label' => __d('admin', 'Price'))));
		if(isset($this->request->params['named']['price'])) echo '</div>';
	?>	
		<div class="form-group row product_description">
			<div class="col-sm-10">
				<label for="ProductDescription">Description (limit 500 character)</label>
				<textarea class="form-control" name="data[Product][description]" maxlength="500"><?php echo @$this->data['Product']['description']?></textarea>
			</div>
		</div>
	<?php
		echo $this->ExtendedForm->input('status', array_merge(array('type' => 'hidden', 'value' =>0, 'label' => __d('admin', 'Status'))));
	?>
<?php echo $this->ExtendedForm->end(array('label' => __d('admin', 'Save Product'), 'class' => 'btn btn-primary', 'div' => false, 'before' => '<div class="form-group">', 'after' => "\n" . $this->Html->link(__d('admin', 'Cancel'), $redirectUrl, array('class' => 'btn btn-default')) . '</div>'));?>
</div>